/*
 * Copyright© 2003-2019 浙江汇信科技有限公司, All Rights Reserved. 
 */
package com.icinfo.cloud.provider.punish.controller;

import com.icinfo.cloud.provider.punish.service.ICaseMainEvidenceService;
import com.icinfo.cloud.provider.punish.ucase.casemain.dto.CaseAppendEvidenceDto;
import com.icinfo.framework.common.web.Result;
import com.icinfo.framework.core.web.BaseController;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.*;

/**
 * 描述: 案件证据表-trj case_main_evidence 对应的Controller类.<br>
 *
 * @author framework generator
 * @date 2022年02月15日
 */
@RestController
@RequestMapping("/evidence")
public class CaseMainEvidenceController extends BaseController {

    @Autowired
    private ICaseMainEvidenceService caseMainEvidenceService;

    /**
     * 证据材料补充
     * @param caseAppendEvidenceDto
     * @return: com.icinfo.framework.common.web.Result
     * @author sunjiefei
     * @date 2023-04-19
     */
    @PostMapping("/appendEvidence")
    public Result appendEvidence(@Validated @RequestBody CaseAppendEvidenceDto caseAppendEvidenceDto){
        return caseMainEvidenceService.appendEvidence(caseAppendEvidenceDto);
    }

    /**
     * 获取证据材料补充
     * @param caseId
     * @return: com.icinfo.framework.common.web.Result
     * @author sunjiefei
     * @date 2023-04-19
     */
    @GetMapping("/getAppendEvidence")
    public Result<CaseAppendEvidenceDto> getAppendEvidence(String caseId){
        return caseMainEvidenceService.getAppendEvidence(caseId);
    }

}